source /home/work_nfs7/xlgeng/.bashrc
dir=/home/work_nfs8/xlgeng/new_workspace/wenet_gxl_salmonn/examples/aishell/salmonn/exp/salmonn_v16/3_epoch
mkdir -p $dir
train_config=conf/train_salmonn_v16.yaml
test_data_dir="/home/work_nfs8/xlgeng/data/scp_test"
test_sets="aishell1 aishell2 test_net test_meeting"

pt_name="step_29988"
scene_name="speechio"
decode_checkpoint=$dir/"${pt_name}".pt
stage=5
stop_stage=5


echo "final checkpoint is $decode_checkpoint"
test_sets=$(echo "$test_sets" | sed 's/ /--/g')


test_data_dir="/home/work_nfs8/xlgeng/data/scp_test"



full_speechio="speechio_0 speechio_1 speechio_2 speechio_3 speechio_4 speechio_5 speechio_6 speechio_7 speechio_8 speechio_9 speechio_10 speechio_11 speechio_12 speechio_13 speechio_14 speechio_15 speechio_16 speechio_17 speechio_18 speechio_19 speechio_20 speechio_21 speechio_22 speechio_23 speechio_24 speechio_24 speechio_26"
half_1="speechio_0 speechio_1 speechio_2 speechio_3 speechio_4 speechio_5 speechio_6 speechio_7 speechio_8 speechio_9 speechio_10 speechio_11 speechio_12 speechio_13"
half_2="speechio_14 speechio_15 speechio_16 speechio_17 speechio_18 speechio_19 speechio_20 speechio_21 speechio_22 speechio_23 speechio_24 speechio_24 speechio_26"



gpu_id="0"
gxl_num="${gpu_id}_common_"
test_sets="test_net speech_io_2"
test_sets=$(echo "$test_sets" | sed 's/ /--/g')
decode_checkpoint_name="${gxl_num}_${pt_name}"
my_named_nohup "${decode_checkpoint_name}${gpu_id}" ./recognize.sh --gpu_id $gpu_id --dir $dir --train_config "$train_config" --decode_checkpoint "$decode_checkpoint" --decode_checkpoint_name "$decode_checkpoint_name" --stage $stage --stop_stage $stop_stage --test_data_dir "$test_data_dir"  --test_sets "$test_sets"

gpu_id="1"
gxl_num="${gpu_id}_common_"
test_sets="aishell2 noise_103 speech_io_3 noise_107"
test_sets=$(echo "$test_sets" | sed 's/ /--/g')
decode_checkpoint_name="${gxl_num}_${pt_name}"
my_named_nohup "${decode_checkpoint_name}${gpu_id}" ./recognize.sh --gpu_id $gpu_id --dir $dir --train_config "$train_config" --decode_checkpoint "$decode_checkpoint" --decode_checkpoint_name "$decode_checkpoint_name" --stage $stage --stop_stage $stop_stage --test_data_dir "$test_data_dir"  --test_sets "$test_sets"

gpu_id="2"
gxl_num="${gpu_id}_common_"
test_sets="speech_io_0 speech_io_1 speech_io_4 test_meeting"
test_sets=$(echo "$test_sets" | sed 's/ /--/g')
decode_checkpoint_name="${gxl_num}_${pt_name}"
my_named_nohup "${decode_checkpoint_name}${gpu_id}" ./recognize.sh --gpu_id $gpu_id --dir $dir --train_config "$train_config" --decode_checkpoint "$decode_checkpoint" --decode_checkpoint_name "$decode_checkpoint_name" --stage $stage --stop_stage $stop_stage --test_data_dir "$test_data_dir"  --test_sets "$test_sets"

gpu_id="3"
gxl_num="${gpu_id}_common_"
test_sets="huawei_noisy huawei_real huawei_accent aishell assistant xiaotiancai"
test_sets=$(echo "$test_sets" | sed 's/ /--/g')
decode_checkpoint_name="${gxl_num}_${pt_name}"
my_named_nohup "${decode_checkpoint_name}${gpu_id}" ./recognize.sh --gpu_id $gpu_id --dir $dir --train_config "$train_config" --decode_checkpoint "$decode_checkpoint" --decode_checkpoint_name "$decode_checkpoint_name" --stage $stage --stop_stage $stop_stage --test_data_dir "$test_data_dir"  --test_sets "$test_sets"


echo "finish!"